
function pxReize(px: number) {
  return (px * document.documentElement.clientWidth) / 1680;
}

export function getOption1() {
  return {
    grid: {
      left: pxReize(20),
      top: pxReize(60),
      bottom: pxReize(10),
      right: pxReize(10),
      containLabel: true
    },
    title: {
      text: "模块标题样式",
      textStyle: {
        color: "#fff",
        fontSize: pxReize(20),
      },
    },
    xAxis: {
      axisLine: {
        show: false,
      },
      axisLabel: {
        show: true,
        fontSize: pxReize(10),
        color: "rgba(255,255,255,.7)",
      },
      data: [
        "商超门店",
        "教育培训",
        "房地产",
        "生活服务",
        "汽车销售",
        "旅游酒店",
        "五金建材",
      ],
    },
    yAxis: {
      axisLine: {
        show: true,
        lineStyle: {
          color: "rgba(255,255,255,.1)",
        },
      },
      splitLine: {
        lineStyle: {
          color: "rgba(255,255,255,.1)",
        },
      },
      axisLabel: {
        color: "rgba(255,255,255,.7)",
        show: true,
        fontSize: pxReize(12),
      },
    },
    series: [
      {
        name: "销量",
        type: "bar",
        data: [200, 300, 400, 900, 1500, 1200, 600],
        barWidth: "30%",
        itemStyle: {
          borderRadius: 5,
          color: "#02a6b5",
        },
      },
    ],
  };
}
